package com.entor.controller;

import javax.annotation.Resource;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import com.entor.model.User;
import com.entor.service.UserService;
import com.hqj.Msg;

@Controller
@RequestMapping("/sys")
public class SystemController {
	
	@Resource(name="userService")
	private UserService us;
	
	@RequestMapping("/login")
	public String login(){
		return "/login";
	}
	
	@RequestMapping("/toLogin")
	@ResponseBody
	public Msg toLogin(User u){
		return us.toLogin(u);
	}
	
	
	
	
	
	
	
	
	
}
